File Share Information Sample Data Processing Extension

© Copyright Microsoft Corporation, 2003. All rights reserved.

 
The SQL Server documentation team cannot answer technical support questions, but welcomes your suggestions and comments about this readme documentation. You can quickly and directly send e-mail feedback using the link below. All feedback must be in English. To submit written feedback about this document, click here:  Submit feedback.
 

This document contains the release information for the Reporting Services FsiDataExtension sample code files. The following sections are included in this Readme:

Overview

FsiDataExtension offers a brief introduction on how to build your own data processing extension. The sample uses the Windows file system as a data source. It uses the .NET Framework library classes DirectoryInfo and FileSystemInfo to query the contents of any valid network file share. The sample uses the data processing extension interfaces as well as other .NET Framework classes. The naming convention used for the sample is the prefix Fsi, or File Share Information.

Topics

The following bullets briefly describe the classes and technologies used by this sample.

Location

The sample code files are located in the Extensions\FsiDataExtension subdirectory of the Reporting Services samples directory.

For Example:

C:\Program Files\Microsoft SQL Server\MSSQL\Reporting Services\Samples\Extensions\FsiDataExtension

Building and deploying the sample

In order to properly build and run this sample, the following steps need to be performed.

To build the sample using the .NET Framework SDK

  1. Copy Microsoft.ReportingServices.Interfaces.dll from the report server \bin directory into your sample folder. By default, Microsoft.ReportingServices.Interfaces.dll is located in C:\Program Files\Microsoft SQL Server\MSSQL\Reporting Services\ReportServer\bin of the computer running report server.

  2. Issue the following command to create the sample data processing extension Microsoft.Samples.ReportingServices.FsiDataExtension.dll.
    csc /t:library /out:Microsoft.Samples.ReportingServices.FsiDataExtension.dll *.cs /r:Microsoft.ReportingServices.Interfaces.dll

To build the sample using Visual Studio .NET

  1. Open FsiDataExtension.sln in Visual Studio .NET.

  2. In Solution Explorer, select the FsiDataExtension project.

  3. On the Project menu, choose Add Reference.

    The Add References dialog box opens.

  4. Choose the .NET tab.

  5. Choose Browse, and find the Microsoft.ReportingServices.Interfaces.dll file on your local drive. By default, the assembly is located in C:\Program Files\Microsoft SQL Server\MSSQL\Reporting Services\ReportServer\bin. Click OK.

    The selected reference is added to your project.

  6. From the Build menu, choose Build Solution.

After you have completed the previous steps, Microsoft.Samples.ReportingServices.FsiDataExtension.dll can be deployed to a report server or to Report Designer for use in running reports against a custom data source.

To deploy the sample

  1. Copy Microsoft.Samples.ReportingServices.FsiDataExtension.dll to the report server. The default location for report server extensions is C:\Program Files\Microsoft SQL Server\MSSQL\Reporting Services\ReportServer\bin.

  2. Copy the assembly to Report Designer. The default location for extensions for Report Designer is C:\Program Files\Microsoft SQL Server\80\Tools\ReportDesigner\bin.

  3. Add the following entry to both the RSReportServer.config and RSReportDesigner.config files under the Data element.
    <Extension Name="FSI" Type="Microsoft.Samples.ReportingServices.FsiDataExtension.FsiConnection,Microsoft.Samples.ReportingServices.FsiDataExtension"/>
  4. To enable the generic query designer for the sample data processing extension, add the following entry to the RSReportDesigner.config file under the Designer element.
    <Extension Name="FSI" Type="Microsoft.ReportDesigner.Design.GenericQueryDesigner,Microsoft.ReportingServices.Designer"/>

To configure code access security for the sample

  1. Open the report server policy configuration file (rssrvpolicy.config). The default location for this file is C:\Program Files\Microsoft SQL Server\MSSQL\Reporting Services\ReportServer.

  2. Data processing extensions must be granted full trust, therefore, add the following code group information to the configuration file:
    <CodeGroup class="UnionCodeGroup"
       version="1"
       PermissionSetName="FullTrust"
       Name="FSICodeGroup"
       Description="Code group for my FSI data processing extension">
          <IMembershipCondition class="UrlMembershipCondition"
             version="1"
             Url="C:\Program Files\Microsoft SQL Server\MSSQL\Reporting Services\ReportServer\bin\Microsoft.Samples.ReportingServices.FsiDataExtension.dll"
           />
    </CodeGroup>
  3. If you are using the sample data processing extension in Report Designer, repeat steps 1 and 2 using the Report Designer preview policy configuration file (rspreviewpolicy.config) and the following code group:
    <CodeGroup class="UnionCodeGroup"
       version="1"
       PermissionSetName="FullTrust"
       Name="FSICodeGroup"
       Description="Code group for my FSI data processing extension">
          <IMembershipCondition class="UrlMembershipCondition"
             version="1"
             Url="C:\Program Files\Microsoft SQL Server\80\Tools\ReportDesigner\bin\Microsoft.Samples.ReportingServices.FsiDataExtension.dll"
           />
    </CodeGroup>

    The default location for the rspreviewpolicy.config file is C:\Program Files\Microsoft SQL Server\80\Tools\ReportDesigner.

Notes

For information about implementing a Reporting Services data processing extension, see "Implementing a Data Processing Extension" in Reporting Services Books Online.